package com.sz.app.edi.rest.edi.track.dto;

import com.sz.app.edi.rest.edi.order.dto.SubOrder;

import javax.xml.bind.annotation.XmlElement;
import javax.xml.bind.annotation.XmlElementWrapper;
import java.math.BigDecimal;
import java.util.ArrayList;
import java.util.List;

/**
 * Function: 通知取货order
 * Author: hpeng.wang. <br>
 * Date: 2017-07-15 10:37:00.
 */
public class NoticeGoodOrder {
    private String waybillNo;
    private String tradeId;
    private String cargoType;
    private Integer packageNum;
    private BigDecimal totalWeight;
    private String sendName;
    private String sendAddress;
    private String sendContact;
    private String receverName;
    private String receverAddress;
    private String receverContact;
    private String trackMessage;
    private String messageTime;
    private List<SubOrder> subOrder = new ArrayList<>();

    public String getWaybillNo() {
        return waybillNo;
    }

    public void setWaybillNo(String waybillNo) {
        this.waybillNo = waybillNo;
    }

    public String getTradeId() {
        return tradeId;
    }

    public void setTradeId(String tradeId) {
        this.tradeId = tradeId;
    }

    public String getCargoType() {
        return cargoType;
    }

    public void setCargoType(String cargoType) {
        this.cargoType = cargoType;
    }

    public Integer getPackageNum() {
        return packageNum;
    }

    public void setPackageNum(Integer packageNum) {
        this.packageNum = packageNum;
    }

    public BigDecimal getTotalWeight() {
        return totalWeight;
    }

    public void setTotalWeight(BigDecimal totalWeight) {
        this.totalWeight = totalWeight;
    }

    public String getSendName() {
        return sendName;
    }

    public void setSendName(String sendName) {
        this.sendName = sendName;
    }

    public String getSendAddress() {
        return sendAddress;
    }

    public void setSendAddress(String sendAddress) {
        this.sendAddress = sendAddress;
    }

    public String getSendContact() {
        return sendContact;
    }

    public void setSendContact(String sendContact) {
        this.sendContact = sendContact;
    }

    public String getReceverName() {
        return receverName;
    }

    public void setReceverName(String receverName) {
        this.receverName = receverName;
    }

    public String getReceverAddress() {
        return receverAddress;
    }

    public void setReceverAddress(String receverAddress) {
        this.receverAddress = receverAddress;
    }

    public String getReceverContact() {
        return receverContact;
    }

    public void setReceverContact(String receverContact) {
        this.receverContact = receverContact;
    }

    public String getTrackMessage() {
        return trackMessage;
    }


    public void setTrackMessage(String trackMessage) {
        this.trackMessage = trackMessage;
    }

    public String getMessageTime() {
        return messageTime;
    }

    public void setMessageTime(String messageTime) {
        this.messageTime = messageTime;
    }

    @XmlElementWrapper(name = "subOrders")
    @XmlElement(name = "subOrder")
    public List<SubOrder> getSubOrder() {
        return subOrder;
    }

    public void setSubOrder(List<SubOrder> subOrder) {
        this.subOrder = subOrder;
    }

    public void addSubOrder(SubOrder subOrder) {
       this.getSubOrder().add(subOrder);
    }
}
